package org.hugoduncan.appam.model;

import java.util.Collection;

/**
 * Interface for an APP WorkspaceComponent.
 * The default collection is handled seperately from the other collections
 * in order to enforce the protocol constraints, ie it must exist and must be listed
 * first.
 *
 * @author duncanhugo
 *
 */
public interface WorkspaceComponent
    extends Component
{
    /**
     * Set the default collection
     * @param collection the default collection
     */
    void setDefaultCollection(CollectionComponent collection);

    /**
     * Get the default collection
     */
    CollectionComponent getDefaultCollection();

    /** Other Collections in the workspace.
     */
    Collection<CollectionComponent> getOtherCollections();

    // add a collection to the component
    void add(CollectionComponent cc);
}
